package com.laikan.reader.core.bean;

import com.google.gson.annotations.SerializedName;

import java.io.Serializable;
import java.util.ArrayList;

/**
 * Created by Administrator on 2016/11/8.
 */
public class ArticleSearchBean {

    @SerializedName ("error_no")
    private String error_no;

    @SerializedName ("error_msg")
    private String error_msg;

    @SerializedName ("result")
    private String result;

    @SerializedName ("data")
    private BookFocusData bookFocusData;

    public String getError_msg() {
        return error_msg;
    }

    public void setError_msg(String error_msg) {
        this.error_msg = error_msg;
    }

    public String getError_no() {
        return error_no;
    }

    public void setError_no(String error_no) {
        this.error_no = error_no;
    }

    public String getResult() {
        return result;
    }

    public void setResult(String result) {
        this.result = result;
    }

    public BookFocusData getBookFocusData() {
        return bookFocusData;
    }

    public void setBookFocusData(BookFocusData bookFocusData) {
        this.bookFocusData = bookFocusData;
    }

    /**
     * data
     */
    public class BookFocusData implements Serializable {

        @SerializedName("list")
        private ArrayList<BookFocusDataList> bookFocusDataList;

        public ArrayList<BookFocusDataList> getBookFocusDataList() {
            return bookFocusDataList;
        }

        public void setBookFocusDataList(ArrayList<BookFocusDataList> bookFocusDataList) {
            this.bookFocusDataList = bookFocusDataList;
        }
    }

    /**
     * data  list
     */
    public class BookFocusDataList implements Serializable {

        @SerializedName("title")
        private String title;

        @SerializedName("shorteId")
        private String shorteId; //详情id

        @SerializedName("intro")
        private String intro; //推广语

        //        @SerializedName("authorId")
        //        private String authorId; //作者id

        @SerializedName("author")
        private String author; //作者姓名

        @SerializedName("img")
        private String img;  //文章图片

        //        @SerializedName("authorPic")
        //        private String authorPic; //作者头像

        @SerializedName("readNum")
        private int readNum; //阅读数

        @SerializedName("isAttention")
        private boolean isAttention; //是否关注

        @SerializedName("type")
        private String type;  //显示样式

        private boolean isSelected = false; //默认未选中

        public boolean isSelected() {
            return isSelected;
        }

        public void setSelected(boolean selected) {
            isSelected = selected;
        }

        public String getTitle() {
            return title;
        }

        public void setTitle(String title) {
            this.title = title;
        }

        public String getShorteId() {
            return shorteId;
        }

        public void setShorteId(String shorteId) {
            this.shorteId = shorteId;
        }

        public String getIntro() {
            return intro;
        }

        public void setIntro(String intro) {
            this.intro = intro;
        }

        public String getAuthor() {
            return author;
        }

        public void setAuthor(String author) {
            this.author = author;
        }

        public String getImg() {
            return img;
        }

        public void setImg(String img) {
            this.img = img;
        }

        public int getReadNum() {
            return readNum;
        }

        public void setReadNum(int readNum) {
            this.readNum = readNum;
        }

        public boolean isAttention() {
            return isAttention;
        }

        public void setAttention(boolean attention) {
            isAttention = attention;
        }

        public String getType() {
            return type;
        }

        public void setType(String type) {
            this.type = type;
        }

        @Override
        public String toString() {
            return "BookFocusDataList{" +
                   "title='" + title + '\'' +
                   ", shorteId='" + shorteId + '\'' +
                   ", intro='" + intro + '\'' +
                   ", author='" + author + '\'' +
                   ", img='" + img + '\'' +
                   ", readNum='" + readNum + '\'' +
                   ", isAttention='" + isAttention + '\'' +
                   ", isSelected='" + isSelected +'\'' +
                   ", type='" + type + '\'' +
                   '}';
        }
    }

    @Override
    public String toString() {
        return "BookFocusBean{" +
               "error_no='" + error_no + '\'' +
               ", error_msg='" + error_msg + '\'' +
               ", result='" + result + '\'' +
               ", bookFocusData=" + bookFocusData +
               '}';
    }
}
